<template>
  <div>
    <swiper :key="loopList.length">
      <div class="swiper-slide" v-for="data in loopList" :key="data.bannerId">
        <img :src="data.imgUrl" alt="">
      </div>
    </swiper>
    <div>film-header</div>
    <router-view></router-view>
  </div>
</template>

<script>
import swiper from '@/views/film/Swiper'

export default {
  data() {
    return {
      loopList: []
    }
  },
  components: {
    swiper
  },
  mounted() {
    fetch('data/test.json').then(res => res.json()).then(res => {
      // console.log(res)
      this.loopList = res.data
    })
  }
}
</script>
